import { ajax } from '@/utils'

const baseUrl = '/yswy-zy-mr-manage'

export default {
  /** mr门店列表 */
  getStoreList(data): Promise<any> {
    return ajax.post(`${baseUrl}/storeManage/list`, data)
  },
  /** 门店添加 */
  addStore(data): Promise<any> {
    return ajax.post(`${baseUrl}/storeManage/create`, data)
  },
  /** 门店详情 */
  getStoreDetail(id): Promise<any> {
    return ajax.get(`${baseUrl}/storeManage/detail/${id}`)
  },
  /** 门店更新 */
  updateStore(data): Promise<any> {
    return ajax.post(`${baseUrl}/storeManage/edit`, data)
  },
  /** 门店启用 */
  activeStore(id): Promise<any> {
    return ajax.get(`${baseUrl}/storeManage/active/${id}`)
  },
  /** 门店禁用 */
  banStore(id): Promise<any> {
    return ajax.get(`${baseUrl}/storeManage/froze/${id}`)
  }
}
